Skip to content

scala 3 syntax for import #1942

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

Merged
merged 1 commit into from
Mar 16, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions _overviews/scala3-book/packaging-imports.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,10 @@ If you’re used to a language like Java, the first class of import statements i
These examples demonstrate some of that flexibility:

````
import users._ // import everything from the `users` package
import users.* // import everything from the `users` package
import users.User // import only the `User` class
import users.{User, UserPreferences} // only import the selected members
import users.{UserPreferences => UPrefs} // rename a member as you import it
import users.{User, UserPreferences} // import only two selected members
import users.{UserPreferences as UPrefs} // rename a member as you import it
````

Those examples are meant to give you a taste of how the first class of `import` statements work.
Expand Down