jsii should reject members named `finalize`
- Dominant language
- TypeScript
- Stars
- 2.9k
- Forks
- 267
- Avg merge
- 1d 25m
- Merged PRs (30d)
- 14
Description
## :bug: Bug Report
### Affected Languages
- [ ] `TypeScript` or `Javascript`
- [ ] `Python`
- [x] `Java`
- [ ] .NET (`C#`, `F#`, ...)
- [ ] `Go`
### What's the problem
If you name a member `finalize`, Java no likey:
```
#STDOUT> [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile) on project assertions: Compilation failure
#STDOUT> [ERROR] /tmp/npm-packdZbR7U/_aws-cdk_assertions/src/main/java/software/amazon/awscdk/assertions/MatchResult.java:[55,93] finalize() in software.amazon.awscdk.assertions.MatchResult cannot override finalize() in java.lang.Object
```
Contributor guide
Research direction
Start by investigating jsii's Java code-generation path for members named `finalize`, using the reported MatchResult.java compilation failure as the reproduction. Add regression coverage for this member name and verify that generated Java code no longer reaches the compiler with the reported override error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, typescript
- Domain
- compilers
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100