Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by Kartack · Oct 08, 2013 at 05:22 PM · javascriptcompiler bug

Upgrade to unity 4.2.1 causing boo compiler error

I upgraded from unity 4.2.0 to 4.2.1. The project compiled under unity 4.2.0 without issue and now it fails to compile in 4.2.1 with the following error: Internal compiler error. See the console log for more information. output was:BCE0011: An error occurred during the execution of the step 'Boo.Lang.Compiler.Steps.EmitAssembly': 'type is not TypeBuilder but System.MonoType Parameter name: type'. The console doesn't appear to really contain any additional useful information. Though if that would help someone in diagnosing it I could add.

The project is a hybrid JavaScript/C# project (not my decision it is how the project was when I inherited it) with various links back and forth between the two languages. I believe the project was started in JavaScript and then later because of them wanting to expand NGUI they started mixing in some C# in a kind of hodge podge sort of way.

This error was apparently happening with Unity 4 when you had empty Javascript files. We do not have any of those (and the project compiles just fine under Unity 4.2.0), I have gone through and double checked to make sure each JS file has the #pragma strict at the top and at least a variable or function declaration.

As well before this compile error started showing up I got some errors that seemed to be about the use of blocks without an if or while before them (basically we had an if statement where we commented out the actual conditional part but had left in the braces that were wrapping the code that the if formerly controlled). To resolve that I simply commented out the braces as well as the if statement itself and those went away. Not sure if that is related but I thought I would add it as well, this struck me as odd.

Any assistance that can be provided would be most valuable as we would like to take advantage of some of the fixes in Unity 4.2.1 for this project.

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by Kartack · Nov 03, 2013 at 07:54 PM

So after a lot of looking through things it turns out that this error is caused by the line: yield null; In C# this is the easiest way to do a wait for one frame, and in versions of unity prior to 4.2.1 it appears as even though it is technically incorrect it wouldn't cause a problem. As of unity 4.2.1 and 4.2.2 however something changed with the compiler and this now causes the above error. The solution to this issue was pretty simple just take all instance of: yield null; and convert them to the correct yield; and the project now compiles properly and appears to function the same as before.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

15 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Can someone help me fix my Javascript for Flickering Light? 6 Answers

Expanding functions 1 Answer

Simple error in void class 1 Answer

Logical Error In Spawn Counter (Javascript) 2 Answers

IOS compiling process deleted all data of the project! 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges