Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
check arguments given to the 'disable' directive
  • Loading branch information
picnixz committed Apr 5, 2025
commit 65c64bc4809b3a996fe05fd5addba8629df1ba8b
7 changes: 6 additions & 1 deletion Tools/clinic/libclinic/dsl_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,12 @@ def at_disable(self, *args: str) -> None:
fail("Can't set @disable, function is not a normal callable")
if not args:
fail("@disable expects at least one argument")
self.disable_fastcall = 'fastcall' in args
features = list(args)
if 'fastcall' in features:
features.remove('fastcall')
self.disable_fastcall = True
if features:
fail("invalid argument for @disable:", features[0])

def at_getter(self) -> None:
match self.kind:
Expand Down