Ceylon IDE M3.2 發布
Ceylon IDE 是基于 Eclipse 的插件,用于開發 Ceylon 編程語言。
Ceylon面向企業級應用開發設計,在JVM運行時基礎上執行,支持與Java的交互操作。Ceylon語言充分借鑒了Java語言的優勢并屏蔽其在設計上的不足,使用靜態類型并提供高階函數支持,在保持代碼良好可讀性的同時進一步降低開發者入門的難度。
Ceylon語言沒有設計特殊的Primitive類型或復合類型,所有類型在類型系統內部都是可表達的。Ceylon的通用類型設計比Java的 實現更為簡便,而且相比其他類Java語言具備更高的安全性,Ceylon的元編程(Reflection)也必須是類型安全的。此外,Ceylon語言 減少了開發者對于配置文件的依賴,屏蔽了Java開發者常常需要對各種XML進行的配置和修改操作。
該版本 100% 兼容之前的 M3.1 版本,在 UI 上做了很大的改進,主要包括:
No more dependence on IMP
We recommend removing IMP from your Eclipse installation.
Ceylon Explorer view
The Ceylon Explorer View presents packages as children of the containing modules. You should reset your Ceylon Perspective after updating the IDE on order to get the Ceylon Explorer in place of JDT's Package Explorer.
Awesome documentation hover
Hover over the name of a Ceylon or Java declaration to see the gorgeous new hover info. Click in it to browse to other related declarations.
Code popup
Ctrl-P
, or "Show Code" pops up an information control containing the code of the referenced declaration. Ctrl-P
again opens an editor. Hyperlink navigation from the Code popup is also possible.
Hierarchy and Outline popups
As before, Ctrl-T
and Ctrl-O
open the popup Hierarchy and Outline views. These now look a lot prettier, and they are also more functional. You can filter the contents by typing inside them, and they remember their bounds. The Hierarchy View is also much better integrated with Java stuff. Ctrl-T
inside the open Hierarchy View cycles between Hierarchy View, Supertypes View, and Subtypes View. These popups have configurable background colors.
Auto-addition of needed imports
Refactorings, quick fixes, and autocompletions now add any needed imports to the top of the source file. In addition, autocompletion will propose declarations from any imported module, even if the package is not imported in the current unit.
New Quick Fixes/Assists
Thanks to Sjur and Tomá?, we now have some new quick fixes and assists:
- convert if/else to then/else, then/else to if/else
- invert if/else
- add type constraint to type parameter
Clean Imports
Clean Imports now automatically fills in missing imports if unambiguous, and prompts the user to choose a declaration to import if ambiguous.
Terminate Statement
Ctrl-2
adds any necessary semicolon, closing parens, and closing braces to terminate the statement at the current line. This feature is almost magical in how good it is at guessing where the closing punctuation needs to go.
Mark occurrences
Occurrence marking is now enabled by default and works like JDT (the declaration to highlight is the one under the caret).
Proposals popups
Completions proposals and quick fix/assist proposal popups now have syntax highlighting. Typing a "." automatically activates the completion proposal window. When only one completion proposal is available, it is automatically applied.
Select Enclosing/Restore Previous Selection
Ctrl-shift-up
expands the selection to the containing expression or program element. Ctrl-shift-down
takes you back to the previous selection.
Also Ctrl-Shift-P
takes you to the matching bracket and Show In now works.
Outline View
There is now a popup context menu on Outline View nodes. The selected node now follows the editor caret location.
Tomá? added a toolbar to the Outline View, letting you filter out local declarations and expand/collapse all nodes.
Open Ceylon Declaration / Open Type
The default keyboard binding for Open Ceylon Declaration is now Ctrl-Shift-O
instead of Ctrl-Shift-C
. This is more ergonomic and works even inside the Java editor. Inside the Ceylon perspective, Ctrl-Shift-T
opens the Open Type dialog, which lets you choose between Ceylon and Java types in one dialog (a very slow-to-load dialog, but hey...).
F3
(Open Selected Declaration) now handles Java declarations.
Support for multiple module repositories
The New Project wizard and Ceylon Preferences page now let you configure multiple module repositories for a project.
Backend errors
Errors from the compiler backend now show up in the Problems View and vertical ruler, and compiler progress is visible in the Progress View and status bar. The 80s-style scrolling console is gone.
Progress
Building the completion proposals and hierarchy for the first time is now expensive because it involves trawling the whole JDK. You get a nice progress bar in the status bar of the main window.
Parser lifecycle
Code is lexed/parsed synchronously on every keypress, and lexed/parsed+typechecked synchronously on every keypress when the completions proposals window is open. This results in much more responsive syntax highlighting and fixes some wierd behavior in the completion proposals window. When the completions proposal window is not open, typechecking still happens in a background job as before.
Download it today
The Ceylon IDE is available today from our update site or from Eclipse Marketplace: