3

How does one refer to a Java package including object in the name such as com.example.object in Scala?

Scala treats object as a reserved word and complains.

1

1 Answer 1

9

Put the reserved word inside backticks, like this:

com.example.`object`
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.