{"action":"opened","issue":{"url":"https://api.github.com/repos/google/closure-stylesheets/issues/70","labels_url":"https://api.github.com/repos/google/closure-stylesheets/issues/70/labels{/name}","comments_url":"https://api.github.com/repos/google/closure-stylesheets/issues/70/comments","events_url":"https://api.github.com/repos/google/closure-stylesheets/issues/70/events","html_url":"https://github.com/google/closure-stylesheets/issues/70","id":114897247,"number":70,"title":"Defining and calling mixins from separate files causes \"Compiler internal error\"","user":{"login":"hochhaus","id":5508784,"avatar_url":"https://avatars.githubusercontent.com/u/5508784?v=3","gravatar_id":"","url":"https://api.github.com/users/hochhaus","html_url":"https://github.com/hochhaus","followers_url":"https://api.github.com/users/hochhaus/followers","following_url":"https://api.github.com/users/hochhaus/following{/other_user}","gists_url":"https://api.github.com/users/hochhaus/gists{/gist_id}","starred_url":"https://api.github.com/users/hochhaus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hochhaus/subscriptions","organizations_url":"https://api.github.com/users/hochhaus/orgs","repos_url":"https://api.github.com/users/hochhaus/repos","events_url":"https://api.github.com/users/hochhaus/events{/privacy}","received_events_url":"https://api.github.com/users/hochhaus/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-11-03T19:59:11Z","updated_at":"2015-11-03T19:59:11Z","closed_at":null,"body":"When defining and calling a mixin in separate source files the compiler currently (both 1.0 and HEAD) result in a \"Compiler internal error\". However, this did not used to be the case. A compiler that I build on Dec 23 2014 compiles these inputs just fine.\r\n\r\n```\r\nahochhaus@ahochhaus-pc:~/test$ cat def.gss \r\n@defmixin spriteUrl() {\r\n  background: url('sprite.png') no-repeat;\r\n}\r\nahochhaus@ahochhaus-pc:~/test$ cat call.gss \r\n.example {\r\n  @mixin spriteUrl();\r\n}\r\nahochhaus@ahochhaus-pc:~/test$ java -jar closure-stylesheets.jar def.gss call.gss\r\nCompiler internal error: com.google.common.css.compiler.ast.CssMixinNode cannot be cast to com.google.common.css.compiler.ast.CssDeclarationNode\r\njava.lang.ClassCastException: com.google.common.css.compiler.ast.CssMixinNode cannot be cast to com.google.common.css.compiler.ast.CssDeclarationNode\r\n        at com.google.common.css.compiler.passes.DisallowDuplicateDeclarations.enterRuleset(DisallowDuplicateDeclarations.java:69)\r\n        at com.google.common.css.compiler.ast.DefaultVisitController$VisitRulesetState.doVisit(DefaultVisitController.java:875)\r\n        at com.google.common.css.compiler.ast.DefaultVisitController.startVisit(DefaultVisitController.java:2028)\r\n        at com.google.common.css.compiler.passes.DisallowDuplicateDeclarations.runPass(DisallowDuplicateDeclarations.java:80)\r\n        at com.google.common.css.compiler.passes.PassRunner.runPasses(PassRunner.java:147)\r\n        at com.google.common.css.compiler.commandline.DefaultCommandLineCompiler.parseAndPrint(DefaultCommandLineCompiler.java:130)\r\n        at com.google.common.css.compiler.commandline.DefaultCommandLineCompiler.compile(DefaultCommandLineCompiler.java:116)\r\n        at com.google.common.css.compiler.commandline.DefaultCommandLineCompiler.execute(DefaultCommandLineCompiler.java:157)\r\n        at com.google.common.css.compiler.commandline.ClosureCommandLineCompiler.executeJob(ClosureCommandLineCompiler.java:335)\r\n        at com.google.common.css.compiler.commandline.ClosureCommandLineCompiler.main(ClosureCommandLineCompiler.java:400)\r\nahochhaus@ahochhaus-pc:~/test$ cat def.gss call.gss > combined.gss\r\nahochhaus@ahochhaus-pc:~/test$ java -jar closure-stylesheets.jar combined.gss \r\n.example{background:url('sprite.png') no-repeat}\r\nahochhaus@ahochhaus-pc:~/test$ java -jar closure-stylesheets-20141223.jar def.gss call.gss \r\n.example{background:url('sprite.png') no-repeat}\r\n```"}}