aboutsummaryrefslogtreecommitdiffstats
path: root/pkg/compiler
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/compiler')
-rw-r--r--pkg/compiler/check.go5
1 files changed, 2 insertions, 3 deletions
diff --git a/pkg/compiler/check.go b/pkg/compiler/check.go
index 7f12d74a5..63268af73 100644
--- a/pkg/compiler/check.go
+++ b/pkg/compiler/check.go
@@ -146,7 +146,6 @@ func (comp *compiler) checkNames() {
}
func (comp *compiler) checkFields() {
- const maxArgs = 9 // executor does not support more
for _, decl := range comp.desc.Nodes {
switch n := decl.(type) {
case *ast.Struct:
@@ -160,9 +159,9 @@ func (comp *compiler) checkFields() {
case *ast.Call:
name := n.Name.Name
comp.checkFieldGroup(n.Args, "argument", "syscall "+name)
- if len(n.Args) > maxArgs {
+ if len(n.Args) > prog.MaxArgs {
comp.error(n.Pos, "syscall %v has %v arguments, allowed maximum is %v",
- name, len(n.Args), maxArgs)
+ name, len(n.Args), prog.MaxArgs)
}
}
}