Skip to content

Commit

Permalink
More meaningful error message for too many selectors
Browse files Browse the repository at this point in the history
  • Loading branch information
James Harkins committed Jun 19, 2012
1 parent 35ff134 commit 9b4a79d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lang/LangSource/PyrParseNode.cpp
Expand Up @@ -4216,7 +4216,7 @@ int conjureSelectorIndex(PyrParseNode *node, PyrBlock* func,
// otherwise add it to the selectors table

if (selectors->size+1 >= 256) {
error("Literal table too big. Simplify the function.\n");
error("Selector table too big: too many classes, method selectors or function definitions in this function. Simplify the function.\n");
post("Next selector was: %s\n", selector->name);
nodePostErrorLine(node);
compileErrors++;
Expand Down Expand Up @@ -4267,7 +4267,7 @@ int conjureLiteralSlotIndex(PyrParseNode *node, PyrBlock* func, PyrSlot *slot)
// otherwise add it to the selectors table

if (selectors->size+1 >= 256) {
error("Literal table too big (>256). Simplify the function.\n");
error("Selector table too big: too many classes, method selectors or function definitions in this function. Simplify the function.\n");
post("Next literal was:\n");
dumpPyrSlot(slot);
nodePostErrorLine(node);
Expand Down

0 comments on commit 9b4a79d

Please sign in to comment.