Quellcode durchsuchen

单行注释中断换行错误

jiedo vor 10 Jahren
Ursprung
Commit
785a3f845c
1 geänderte Dateien mit 2 neuen und 4 gelöschten Zeilen
  1. 2 4
      eBook/10.1.md

+ 2 - 4
eBook/10.1.md

@@ -265,10 +265,8 @@ type nr number   // alias type
 func main() {
     a := number{5.0}
     b := nr{5.0}
-    // var i float32 = b   // compile-error: cannot use b (type nr) as type 
-    float32 in assignment
-    // var i = float32(b)  // compile-error: cannot convert b (type nr) to 
-    type float32
+    // var i float32 = b   // compile-error: cannot use b (type nr) as type float32 in assignment
+    // var i = float32(b)  // compile-error: cannot convert b (type nr) to type float32
     // var c number = b    // compile-error: cannot use b (type nr) as type number in assignment
     // needs a conversion:
     var c = number(b)