Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ExpressionDecomposer throws IllegalStateException: Object method calls can not be decomposed #3220

Open
rohanpadhye opened this issue Jan 27, 2019 · 1 comment
Labels
internal-issue-created An internal Google issue has been created to track this GitHub issue triage-done Has been reviewed by someone on triage rotation.

Comments

@rohanpadhye
Copy link

Fuzzing with JQF led to the following discovery:

o_0 => i_1 &= (undefined[(i_1 => { i_1 })(y_3)])(true)

Compiling with SIMPLE_OPTIMIZATIONS throws:

java.lang.IllegalStateException: Object method calls can not be decomposed.
	at com.google.common.base.Preconditions.checkState(Preconditions.java:507)
	at com.google.javascript.jscomp.ExpressionDecomposer.exposeExpression(ExpressionDecomposer.java:187)
	at com.google.javascript.jscomp.ExpressionDecomposer.exposeExpression(ExpressionDecomposer.java:127)
	at com.google.javascript.jscomp.ExpressionDecomposer.maybeExposeExpression(ExpressionDecomposer.java:109)
	at com.google.javascript.jscomp.FunctionInjector$CallSiteType$6.prepare(FunctionInjector.java:421)
	at com.google.javascript.jscomp.FunctionInjector.maybePrepareCall(FunctionInjector.java:498)
	at com.google.javascript.jscomp.InlineFunctions.decomposeExpressions(InlineFunctions.java:785)
	at com.google.javascript.jscomp.InlineFunctions.process(InlineFunctions.java:142)
	at com.google.javascript.jscomp.PhaseOptimizer$NamedPass.process(PhaseOptimizer.java:310)
	at com.google.javascript.jscomp.PhaseOptimizer$Loop.process(PhaseOptimizer.java:455)
	at com.google.javascript.jscomp.PhaseOptimizer.process(PhaseOptimizer.java:231)
	at com.google.javascript.jscomp.Compiler.performOptimizations(Compiler.java:2384)
	at com.google.javascript.jscomp.Compiler.lambda$stage2Passes$1(Compiler.java:795)
	at com.google.javascript.jscomp.CompilerExecutor$2.call(CompilerExecutor.java:102
...

Repro link

@tjgq
Copy link
Contributor

tjgq commented Jan 28, 2019

Created Google internal issue b/123528334

@tjgq tjgq added triage-done Has been reviewed by someone on triage rotation. internal-issue-created An internal Google issue has been created to track this GitHub issue labels Jan 28, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
internal-issue-created An internal Google issue has been created to track this GitHub issue triage-done Has been reviewed by someone on triage rotation.
Projects
None yet
Development

No branches or pull requests

2 participants