瀏覽代碼

* implemented objcprotocol for now with a call to objc_GetProtocol()

git-svn-id: branches/objc@13730 -
Jonas Maebe 16 年之前
父節點
當前提交
c9a6e32f16
共有 1 個文件被更改,包括 5 次插入2 次删除
  1. 5 2
      compiler/nobjc.pas

+ 5 - 2
compiler/nobjc.pas

@@ -162,8 +162,11 @@ function tobjcprotocolnode.pass_typecheck: tnode;
 
 function tobjcprotocolnode.pass_1: tnode;
   begin
-    result:=nil;
-    expectloc:=LOC_CREFERENCE;
+    result:=ccallnode.createinternresfromunit('OBJC1','OBJC_GETPROTOCOL',
+      ccallparanode.create(cstringconstnode.createstr(tobjectdef(left.resultdef).objextname^),nil),
+      resultdef
+    );
+    typecheckpass(result);
   end;