This repository was archived by the owner on Oct 1, 2024. It is now read-only.
Fix build failure with mcs caused by C#8 changes in mcs#264
Merged
marek-safar merged 1 commit intomono:gtk-sharp-2-12-branchfrom Feb 20, 2019
Merged
Fix build failure with mcs caused by C#8 changes in mcs#264marek-safar merged 1 commit intomono:gtk-sharp-2-12-branchfrom
marek-safar merged 1 commit intomono:gtk-sharp-2-12-branchfrom
Conversation
Recent addition of C#8 features to mcs possibly broke this: ``` mcs -out:WidgetViewer.exe -r:../../glib/glib-sharp.dll -r:../../pango/pango-sharp.dll -r:../../atk/atk-sharp.dll -r:../../gdk/gdk-sharp.dll -r:../../gtk/gtk-sharp.dll ./TestCheckButton.cs ./TestColorSelection.cs ./TestRadioButton.cs ./TestRange.cs ./TestStatusbar.cs ./TestDialog.cs ./TestFlipping.cs ./TestSizeGroup.cs ./TestCombo.cs ./TestComboBox.cs ./WidgetViewer.cs ./TestCombo.cs(17,14): warning CS0612: `Gtk.Combo' is obsolete ./TestRange.cs(35,6): error CS0104: `Range' is an ambiguous reference between `System.Range' and `Gtk.Range' @/external/bockbuild/stage/lib/mono/4.5/mscorlib.dll (Location of the symbol related to previous error) @/external/bockbuild/builds/gtk-sharp-None/sample/test/../../gtk/gtk-sharp.dll (Location of the symbol related to previous error) ./TestRange.cs(35,13): error CS0030: Cannot convert type `Gtk.HScale' to `System.Range' ./TestRange.cs(42,6): error CS0104: `Range' is an ambiguous reference between `System.Range' and `Gtk.Range' @/external/bockbuild/stage/lib/mono/4.5/mscorlib.dll (Location of the symbol related to previous error) @/external/bockbuild/builds/gtk-sharp-None/sample/test/../../gtk/gtk-sharp.dll (Location of the symbol related to previous error) ./TestRange.cs(42,13): error CS0030: Cannot convert type `Gtk.HScrollbar' to `System.Range' ./TestRange.cs(62,6): error CS0104: `Range' is an ambiguous reference between `System.Range' and `Gtk.Range' @/external/bockbuild/stage/lib/mono/4.5/mscorlib.dll (Location of the symbol related to previous error) @/external/bockbuild/builds/gtk-sharp-None/sample/test/../../gtk/gtk-sharp.dll (Location of the symbol related to previous error) ./TestRange.cs(62,13): error CS0030: Cannot convert type `Gtk.VScale' to `System.Range' ``` This is because the compiler is resolving `Range` in the test as `System.Range` instead of `Gtk.Range`, so we disambiguate it. /cc @marek-safar
radical
added a commit
to radical/bockbuild-1
that referenced
this pull request
Feb 20, 2019
radical
added a commit
to mono/bockbuild
that referenced
this pull request
Feb 20, 2019
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Recent addition of C#8 features to mcs possibly broke this:
This is because the compiler is resolving
Rangein the test asSystem.Rangeinstead of
Gtk.Range, so we disambiguate it./cc @marek-safar
Prompted by: mono/bockbuild#88 (comment)