{"action":"created","issue":{"url":"https://api.github.com/repos/D-Programming-Language/dub/issues/765","repository_url":"https://api.github.com/repos/D-Programming-Language/dub","labels_url":"https://api.github.com/repos/D-Programming-Language/dub/issues/765/labels{/name}","comments_url":"https://api.github.com/repos/D-Programming-Language/dub/issues/765/comments","events_url":"https://api.github.com/repos/D-Programming-Language/dub/issues/765/events","html_url":"https://github.com/D-Programming-Language/dub/issues/765","id":130497092,"number":765,"title":"version 0.3.0 generates invalid code.","user":{"login":"SuperDoxin","id":377239,"avatar_url":"https://avatars.githubusercontent.com/u/377239?v=3","gravatar_id":"","url":"https://api.github.com/users/SuperDoxin","html_url":"https://github.com/SuperDoxin","followers_url":"https://api.github.com/users/SuperDoxin/followers","following_url":"https://api.github.com/users/SuperDoxin/following{/other_user}","gists_url":"https://api.github.com/users/SuperDoxin/gists{/gist_id}","starred_url":"https://api.github.com/users/SuperDoxin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SuperDoxin/subscriptions","organizations_url":"https://api.github.com/users/SuperDoxin/orgs","repos_url":"https://api.github.com/users/SuperDoxin/repos","events_url":"https://api.github.com/users/SuperDoxin/events{/privacy}","received_events_url":"https://api.github.com/users/SuperDoxin/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-02-01T21:57:34Z","updated_at":"2016-02-03T13:13:11Z","closed_at":"2016-02-03T13:13:11Z","body":"given this grammar:\r\n\r\n    assemblyFile:\r\n    list <- line+ EOF\r\n    line <- :WS? comment / instruction\r\n    comment <- :';' ~((!'\\n' .)*) EOL / EOL\r\n    label_list <- (label :WS?)*\r\n    label <- ~(!opcode ([a-zA-Z_] [a-zA-Z0-9_]*))\r\n    operation <- opcode :'.' modifier / opcode\r\n    opcode <- 'DAT' / 'MOV' / 'ADD' / 'SUB' / 'MUL' / 'DIV' / 'MOD' / 'JMP' /\r\n             'JMZ' / 'JMN' / 'DJN' / 'CMP' / 'SLT' / 'SPL' / 'SNE' / 'SEQ' / 'ORG' / 'EQU' / \r\n             'END'\r\n    modifier <- 'AB' / 'BA' / 'A' / 'B' / 'F' / 'X' / 'I' / eps\r\n    mode <- '#' / '$' / '@' / '<' / '>' / '{' / '}' / '*' / eps\r\n    expr <- '(' expr ')' / term '%' expr / term '/' expr / term '*' expr / term '-' expr /\r\n           term '+' expr / term\r\n    term <- label / number / expr\r\n    number <- whole_number / signed_integer\r\n    signed_integer <~ '+' whole_number / '-' whole_number\r\n    whole_number <~ [0-9]+\r\n    WS <- ' '+\r\n    EOL <- :'\\n' / EOF\r\n    EOF <- !.\r\n    \r\n    instruction <- label_list :WS? operation :WS? mode :WS? expr :WS? ',' :WS? mode :WS? expr :WS? comment / \r\n                   label_list :WS? operation :WS? mode :WS? expr :WS? comment\r\n\r\nit generates unreachable code, which is a warning, which under dub defaults to an error.\r\n\r\nwhen you then disable generating errors for warnings it fails to link:\r\n\r\n\r\n    Performing \"debug\" build using dmd for x86_64.\r\n    pegged 0.3.0: target for configuration \"library\" is up to date.\r\n    redparser ~master: building configuration \"application\"...\r\n    source/parser.d-mixin-189(654,133): Warning: statement is not reachable\r\n    Linking...\r\n    .dub/build/application-debug-linux.posix-x86_64-dmd_2069-7BC6E58A413187F61AFD3B46A6522C12/redparser.o: In function `_D6pegged7grammar44__T7grammarVE6pegged7grammar11Memoizationi1Z7grammarFAyaZ21leftRecursionStoppersMFNaZAAya':\r\n    /home/lieuwe/Desktop/dlang/redparser/../../../.dub/packages/pegged-0.3.0/pegged/grammar.d:115: undefined reference to `_D6pegged13introspection8ruleInfoFNaS6pegged3peg9ParseTreeZHAyaS6pegged13introspection8RuleInfo'\r\n    .dub/build/application-debug-linux.posix-x86_64-dmd_2069-7BC6E58A413187F61AFD3B46A6522C12/redparser.o:(.data._D41TypeInfo_S6pegged13introspection8RuleInfo6__initZ+0x30): undefined reference to `_D6pegged13introspection8RuleInfo9__xtoHashFNbNeKxS6pegged13introspection8RuleInfoZm'\r\n    .dub/build/application-debug-linux.posix-x86_64-dmd_2069-7BC6E58A413187F61AFD3B46A6522C12/redparser.o:(.data._D41TypeInfo_S6pegged13introspection8RuleInfo6__initZ+0x38): undefined reference to `_D6pegged13introspection8RuleInfo11__xopEqualsFKxS6pegged13introspection8RuleInfoKxS6pegged13introspection8RuleInfoZb'\r\n    collect2: error: ld returned 1 exit status\r\n    --- errorlevel 1\r\n    dmd failed with exit code 1.\r\n\r\nnow I'm sure I did something wrong here, but I can't figure out what's going on inside that mixin.\r\n\r\nNOTE: this exact same grammar *did* work using 0.2.1"},"comment":{"url":"https://api.github.com/repos/D-Programming-Language/dub/issues/comments/179222095","html_url":"https://github.com/D-Programming-Language/dub/issues/765#issuecomment-179222095","issue_url":"https://api.github.com/repos/D-Programming-Language/dub/issues/765","id":179222095,"user":{"login":"SuperDoxin","id":377239,"avatar_url":"https://avatars.githubusercontent.com/u/377239?v=3","gravatar_id":"","url":"https://api.github.com/users/SuperDoxin","html_url":"https://github.com/SuperDoxin","followers_url":"https://api.github.com/users/SuperDoxin/followers","following_url":"https://api.github.com/users/SuperDoxin/following{/other_user}","gists_url":"https://api.github.com/users/SuperDoxin/gists{/gist_id}","starred_url":"https://api.github.com/users/SuperDoxin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SuperDoxin/subscriptions","organizations_url":"https://api.github.com/users/SuperDoxin/orgs","repos_url":"https://api.github.com/users/SuperDoxin/repos","events_url":"https://api.github.com/users/SuperDoxin/events{/privacy}","received_events_url":"https://api.github.com/users/SuperDoxin/received_events","type":"User","site_admin":false},"created_at":"2016-02-03T13:13:11Z","updated_at":"2016-02-03T13:13:11Z","body":"oops I opened an issue on the wrong project. apologies."}}