eclipse-corrosion / corrosion

Eclipse Corrosion - Rust edition in Eclipse IDE
Eclipse Public License 2.0
223 stars 31 forks source link

First vertical split since launch loses syntax coloring #378

Open cplir-c opened 3 years ago

cplir-c commented 3 years ago

On the new june build of corrosion (1.2.1.202106081156) and eclipse 2020-12 doing Window -> Editor -> Split Editor (Vertical) for the first time since eclipse launch on a 200 line rust file results in the second pane consistently being uncolored. It also happens when I leave the vertical split open and restart eclipse.

Originally posted by @cplir-c in https://github.com/eclipse/corrosion/issues/243#issuecomment-873763215

hydra commented 3 years ago

I noticed the same issue today.

Eclipse Version: 2021-06 (4.20.0) Corrosion: 1.2.1.202106081156

akurtakov commented 2 years ago

Do you still face this issue with latest version?

hydra commented 2 years ago

@akurtakov I switched to using CLion for rust development. I don't have enough free time to follow up on this, maybe @cplir-c can test it?

cplir-c commented 2 years ago

The first vertical split since launch looks to color properly, but if I leave a vertical split open and restart eclipse the right pane isn't colored. I was testing using a 200 line, 100 line, and 30 line rust file and they all worked similarly.

If I open a vertical split on my cargo.toml file though, it doesn't color even if I don't restart Eclipse.

If I close and reopen the vertical split, it syntax colors. Tested with my cargo.toml and a 30 line rust file.

eclipse version: Version: 2022-06 (4.24.0) Build id: 20220609-1112

corrosion version: Corrosion: 1.2.4.202206282034

I had installed eclipse-cpp using the eclipse installer and downloaded corrosion from the eclipse marketplace.

mickaelistria commented 2 years ago

I couldn't reproduce on my Fedora workstation. Can you please share details about your environment? And maybe share some files and details to reproduce the issue from a fresh workspace?

hydra commented 2 years ago

Hi, I just tried this again today, the color now appears on the pane on the right, but if the IDE is them restarted, the pane on the right is uncolored.

Here's the short details of my installation:

Version: 2022-06 (4.24.0)
Build id: 20220609-1112

  C/C++ Autotools support   10.7.0.202205060838 org.eclipse.cdt.autotools.feature.group Eclipse CDT
  C/C++ CMake Build Support - Preview   10.7.0.202206081803 org.eclipse.cdt.cmake.feature.group Eclipse CDT
  C/C++ Debug Adapter GDB Debugger Integration  10.7.0.202204200013 org.eclipse.cdt.debug.dap.feature.group Eclipse CDT
  C/C++ Debug Adapter GDB Hardware Debugger Integration 10.7.0.202204200013 org.eclipse.cdt.debug.dap.gdbjtag.feature.group Eclipse CDT
  C/C++ Development Tools   10.7.0.202206081808 org.eclipse.cdt.feature.group   Eclipse CDT
  C/C++ Docker Container Launch Support 10.7.0.202205210108 org.eclipse.cdt.docker.launcher.feature.group   Eclipse CDT
  C/C++ GCC Cross Compiler Support  10.7.0.202204200013 org.eclipse.cdt.build.crossgcc.feature.group    Eclipse CDT
  C/C++ GDB Hardware Debugging  10.7.0.202204241640 org.eclipse.cdt.debug.gdbjtag.feature.group Eclipse CDT
  C/C++ Launch over Serial  10.7.0.202204200013 org.eclipse.cdt.launch.serial.feature.feature.group Eclipse CDT
  C/C++ Library API Documentation Hover Help    8.7.0.202206072042  org.eclipse.linuxtools.cdt.libhover.feature.feature.group   Eclipse Linux Tools
  C/C++ Memory View Enhancements    10.7.0.202204200013 org.eclipse.cdt.debug.ui.memory.feature.group   Eclipse CDT
  C/C++ Meson Build Support - Preview   10.7.0.202204200013 org.eclipse.cdt.meson.feature.group Eclipse CDT
  C/C++ Remote Launch   10.7.0.202205060838 org.eclipse.cdt.launch.remote.feature.group Eclipse CDT
  C/C++ Standalone Debugger 10.7.0.202204200013 org.eclipse.cdt.debug.standalone.feature.group  Eclipse CDT
  C/C++ Test runner client for UnitTest View    10.7.0.202204200013 org.eclipse.cdt.unittest.feature.feature.group  Eclipse CDT
  C/C++ Unit Testing Support    10.7.0.202204200013 org.eclipse.cdt.testsrunner.feature.feature.group   Eclipse CDT
  ChangeLog Management Tools for C/C++  8.7.0.202206072042  org.eclipse.linuxtools.changelog.c.feature.group    Eclipse Linux Tools
  Corrosion: Rust edition in Eclipse IDE    1.2.4.202206282034  org.eclipse.corrosion.feature.feature.group Eclipse Corrosion
  Eclipse IDE for Embedded C/C++ Developers 4.24.0.20220609-1200    epp.package.embedcpp    Eclipse Packaging Project
  Eclipse Java Development Tools    3.18.1200.v20220607-0700    org.eclipse.jdt.feature.group   Eclipse.org
  Eclipse Java EE Developer Tools   3.26.0.v202204042240    org.eclipse.jst.enterprise_ui.feature.feature.group Eclipse Web Tools Platform
  Eclipse Web Developer Tools   3.26.0.v202204091445    org.eclipse.wst.web_ui.feature.feature.group    Eclipse Web Tools Platform
  Eclipse XML Editors and Tools 3.26.0.v202204091445    org.eclipse.wst.xml_ui.feature.feature.group    Eclipse Web Tools Platform
  Embedded C/C++ ADuCM360 Project Template  6.2.1.202204041943  org.eclipse.embedcdt.templates.ad.feature.group Eclipse Embedded CDT
  Embedded C/C++ Arm Cross Compiler 6.2.1.202204041943  org.eclipse.embedcdt.managedbuild.cross.arm.feature.group   Eclipse Embedded CDT
  Embedded C/C++ CMSIS Packs (Experimental) 6.2.1.202204041943  org.eclipse.embedcdt.packs.feature.group    Eclipse Embedded CDT
  Embedded C/C++ CodeRed Debug Perspective  6.2.1.202204041943  org.eclipse.embedcdt.codered.feature.group  Eclipse Embedded CDT
  Embedded C/C++ Core   6.2.1.202204041943  org.eclipse.embedcdt.feature.group  Eclipse Embedded CDT
  Embedded C/C++ Documentation (Placeholder)    6.2.1.202204041943  org.eclipse.embedcdt.doc.user.feature.group Eclipse Embedded CDT
  Embedded C/C++ Freescale Project Templates    6.2.1.202204041943  org.eclipse.embedcdt.templates.freescale.feature.group  Eclipse Embedded CDT
  Embedded C/C++ GDB JTAG Debugging 6.2.1.202204041943  org.eclipse.embedcdt.debug.gdbjtag.feature.group    Eclipse Embedded CDT
  Embedded C/C++ Generic Cortex-M Project Template  6.2.1.202204041943  org.eclipse.embedcdt.templates.cortexm.feature.group    Eclipse Embedded CDT
  Embedded C/C++ J-Link Debugging   6.2.1.202204041943  org.eclipse.embedcdt.debug.gdbjtag.jlink.feature.group  Eclipse Embedded CDT
  Embedded C/C++ OpenOCD Debugging  6.2.1.202204041943  org.eclipse.embedcdt.debug.gdbjtag.openocd.feature.group    Eclipse Embedded CDT
  Embedded C/C++ PyOCD Debugging    6.2.1.202204041943  org.eclipse.embedcdt.debug.gdbjtag.pyocd.feature.group  Eclipse Embedded CDT
  Embedded C/C++ QEMU Debugging 6.2.1.202204041943  org.eclipse.embedcdt.debug.gdbjtag.qemu.feature.group   Eclipse Embedded CDT
  Embedded C/C++ RISC-V Cross Compiler  6.2.1.202204041943  org.eclipse.embedcdt.managedbuild.cross.riscv.feature.group Eclipse Embedded CDT
  Embedded C/C++ SiFive RISC-V Project Template 6.2.1.202204041943  org.eclipse.embedcdt.templates.sifive.feature.group Eclipse Embedded CDT
  Embedded C/C++ STM32Fx Project Templates  6.2.1.202204041943  org.eclipse.embedcdt.templates.stm.feature.group    Eclipse Embedded CDT
  GCov Integration  8.7.0.202206072042  org.eclipse.linuxtools.gcov.feature.group   Eclipse Linux Tools
  GDB Tracepoint Analysis   8.0.0.202206082347  org.eclipse.tracecompass.gdbtrace.feature.group Eclipse Trace Compass
  Git integration for Eclipse   6.2.0.202206071550-r    org.eclipse.egit.feature.group  Eclipse EGit
  GProf Integration 8.7.0.202206072042  org.eclipse.linuxtools.gprof.feature.feature.group  Eclipse Linux Tools
  Java implementation of Git    6.2.0.202206071550-r    org.eclipse.jgit.feature.group  Eclipse JGit
  JavaScript Development Tools  2.4.200.v202204112136   org.eclipse.wst.jsdt.feature.feature.group  Eclipse Web Tools Platform
  JUnit Test runner client for UnitTest View    1.0.200.v20220204-2234  org.eclipse.jdt.ui.unittest.junit.feature.feature.group Eclipse.org
  JustJ Adoptium OpenJDK Hotspot JRE Complete   17.0.3.v20220515-1416   org.eclipse.justj.openjdk.hotspot.jre.full.feature.group    Eclipse JustJ
  LaunchBar 10.7.0.202204200013 org.eclipse.launchbar.feature.group Eclipse CDT
  Library Hover help for devhelp documentation  8.7.0.202206072042  org.eclipse.linuxtools.cdt.libhover.devhelp.feature.feature.group   Eclipse Linux Tools
  LTTng Kernel Analysis 8.0.0.202206082347  org.eclipse.tracecompass.lttng2.kernel.feature.group    Eclipse Trace Compass
  LTTng Tracer Control  8.0.0.202206082347  org.eclipse.tracecompass.lttng2.control.feature.group   Eclipse Trace Compass
  LTTng Userspace Analysis  8.0.0.202206082347  org.eclipse.tracecompass.lttng2.ust.feature.group   Eclipse Trace Compass
  Marketplace Client    1.10.0.v20220502-0731   org.eclipse.epp.mpc.feature.group   Eclipse Marketplace Client
  Mylyn WikiText    3.0.42.202201072301 org.eclipse.mylyn.wikitext_feature.feature.group    Eclipse Mylyn
  Oomph Setup   1.25.0.v20220607-1104   org.eclipse.oomph.setup.feature.group   Eclipse Oomph Project
  Remote Launch Targets 10.7.0.202204200013 org.eclipse.launchbar.remote.feature.group  Eclipse CDT
  RPM Tools 8.7.0.202206072042  org.eclipse.linuxtools.rpm.feature.group    Eclipse Linux Tools
  ShellWax  1.2.0.20220712-1356 org.eclipse.shellwax.feature.feature.group  null
  TM Terminal   10.7.0.202204110055 org.eclipse.tm.terminal.feature.feature.group   Eclipse CDT
  TM Terminal Serial Connector Extensions   10.7.0.202204200013 org.eclipse.tm.terminal.connector.cdtserial.feature.feature.group   Eclipse CDT
  Valgrind Tools Integration    8.7.0.202206072042  org.eclipse.linuxtools.valgrind.feature.group   Eclipse Linux Tools

Here's the full details of my installation: log.txt

I started with the latest CDT package, and then installed other plugins and features afterwards.

hydra commented 2 years ago

Here's a screenshot of the issue: Screenshot 2022-08-24 155706

Here's the workspace: 4.24-rust-corrosion-378.zip

Here's the demo project the workspace uses, which is just a new cargo project, and also contains the eclipse project and settings for it: hello-world.zip