mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-11-16 11:40:42 +00:00
Fixed: Should be 'objj_allocateProtocol' and 'objj_registerProtocol' not 'objc_allocateProtocol' and 'objc_registerProtocol'
This commit is contained in:
1 parent
c979a69e6b
commit
ba0604320e
2 files changed
+6
-6
No files matched your search
@@ -1836,7 +1836,7 @@ ProtocolDeclarationStatement: function(node, st, c) {
|
||||
|
||||
if (!generate) buffer.concat(compiler.source.substring(compiler.lastPos, node.start));
|
||||
|
||||
buffer.concat("{var the_protocol = objc_allocateProtocol(\"" + protocolName + "\");");
|
||||
buffer.concat("{var the_protocol = objj_allocateProtocol(\"" + protocolName + "\");");
|
||||
|
||||
if (protocols) for (var i = 0, size = protocols.length; i < size; i++)
|
||||
{
|
||||
@@ -1874,7 +1874,7 @@ ProtocolDeclarationStatement: function(node, st, c) {
|
||||
}
|
||||
}
|
||||
|
||||
buffer.concat("\nobjc_registerProtocol(the_protocol);\n");
|
||||
buffer.concat("\nobjj_registerProtocol(the_protocol);\n");
|
||||
|
||||
// Add instance methods
|
||||
if (compiler.imBuffer.isEmpty())
|
||||
@@ -1932,8 +1932,8 @@ MethodDeclarationStatement: function(node, st, c) {
|
||||
|
||||
types.push(argumentType ? argumentType.name : "id");
|
||||
|
||||
if (argumentProtocols) for (var i = 0, size = argumentProtocols.length; i < size; i++) {
|
||||
var argumentProtocol = argumentProtocols[i];
|
||||
if (argumentProtocols) for (var j = 0, size = argumentProtocols.length; j < size; j++) {
|
||||
var argumentProtocol = argumentProtocols[j];
|
||||
if (!compiler.getProtocolDef(argumentProtocol.name)) {
|
||||
compiler.addWarning(createMessage("Cannot find protocol declaration for '" + argumentProtocol.name + "'", argumentProtocol, compiler.source));
|
||||
}
|
||||
|
||||
@@ -376,14 +376,14 @@ GLOBAL(protocol_conformsToProtocol) = function(/*Protocol*/ p1, /*Protocol*/ p2)
|
||||
|
||||
var REGISTERED_PROTOCOLS = { };
|
||||
|
||||
GLOBAL(objc_allocateProtocol) = function(/*String*/ aName)
|
||||
GLOBAL(objj_allocateProtocol) = function(/*String*/ aName)
|
||||
{
|
||||
var protocol = new objj_protocol(aName);
|
||||
|
||||
return protocol;
|
||||
}
|
||||
|
||||
GLOBAL(objc_registerProtocol) = function(/*Protocol*/ proto)
|
||||
GLOBAL(objj_registerProtocol) = function(/*Protocol*/ proto)
|
||||
{
|
||||
REGISTERED_PROTOCOLS[proto.name] = proto;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user