diff --git a/components/codetools/examples/scanexamples/objctest1.pas b/components/codetools/examples/scanexamples/objctest1.pas index ffa446b5ff..1381f739c8 100644 --- a/components/codetools/examples/scanexamples/objctest1.pas +++ b/components/codetools/examples/scanexamples/objctest1.pas @@ -35,6 +35,11 @@ type private end; + NSAlertDelegateProtocol = objcprotocol external name 'NSAlertDelegate' + optional + function alertShowHelp(alert: NSAlert): Boolean; message 'alertShowHelp:'; + end; + implementation end. diff --git a/components/codetools/pascalparsertool.pas b/components/codetools/pascalparsertool.pas index 18f48720eb..85904aeb0e 100644 --- a/components/codetools/pascalparsertool.pas +++ b/components/codetools/pascalparsertool.pas @@ -3846,7 +3846,7 @@ begin ReadNextAtom; end; end - else if UpAtomIs('EXTERNAL') and (ClassDesc in [ctnObjCClass,ctnObjCCategory]) then + else if UpAtomIs('EXTERNAL') and (ClassDesc in [ctnObjCClass,ctnObjCCategory,ctnObjCProtocol]) then begin CreateChildNode; CurNode.Desc:=ctnClassExternal;