OXIESEC PANEL
- Current Dir:
/
/
opt
/
golang
/
1.22.0
/
test
/
abi
Server IP: 2a02:4780:11:1084:0:327f:3464:10
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
02/02/2024 06:09:55 PM
rwxr-xr-x
📄
bad_internal_offsets.go
1.39 KB
02/02/2024 06:09:55 PM
rw-r--r--
📄
bad_select_crash.go
5.73 KB
02/02/2024 06:09:55 PM
rw-r--r--
📄
convF_criteria.go
424 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
convF_criteria.out
25 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
convT64_criteria.go
387 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
convT64_criteria.out
17 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
defer_aggregate.go
846 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
defer_recover_results.go
800 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
double_nested_addressed_struct.go
1.29 KB
02/02/2024 06:09:55 PM
rw-r--r--
📄
double_nested_struct.go
1.11 KB
02/02/2024 06:09:55 PM
rw-r--r--
📄
f_ret_z_not.go
616 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
f_ret_z_not.out
2 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
fibish.go
510 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
fibish.out
25 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
fibish_closure.go
658 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
fibish_closure.out
25 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
fuzz_trailing_zero_field.go
551 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
idata.go
2.06 KB
02/02/2024 06:09:55 PM
rw-r--r--
📄
idata.out
10 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
leaf.go
641 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
leaf2.go
768 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
many_int_input.go
908 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
many_int_input.out
69 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
many_intstar_input.go
967 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
many_intstar_input.out
26 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
map.go
557 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
method_wrapper.go
637 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
more_intstar_input.go
976 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
more_intstar_input.out
23 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
named_results.go
1.36 KB
02/02/2024 06:09:55 PM
rw-r--r--
📄
named_results.out
198 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
named_return_stuff.go
1.5 KB
02/02/2024 06:09:55 PM
rw-r--r--
📄
named_return_stuff.out
198 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
open_defer_1.go
627 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
part_live.go
823 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
part_live_2.go
986 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
reg_not_ssa.go
532 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
result_live.go
510 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
result_regalloc.go
765 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
return_stuff.go
700 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
return_stuff.out
36 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
s_sif_sif.go
651 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
spills3.go
826 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
spills4.go
753 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
store_reg_args.go
587 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
struct_3_string_input.go
727 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
struct_3_string_input.out
0 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
struct_lower_1.go
441 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
struct_lower_1.out
10 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
too_big_to_ssa.go
833 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
too_big_to_ssa.out
37 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
uglyfib.go
1.45 KB
02/02/2024 06:09:55 PM
rw-r--r--
📄
uglyfib.out
18 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
wrapdefer_largetmp.go
453 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
wrapdefer_largetmp.out
2 bytes
02/02/2024 06:09:55 PM
rw-r--r--
📄
zombie_struct_select.go
676 bytes
02/02/2024 06:09:55 PM
rw-r--r--
Editing: idata.go
Close
// run // Copyright 2021 The Go Authors. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. // Excerpted from go/constant/value.go to capture a bug from there. package main import ( "fmt" "math" "math/big" ) type ( unknownVal struct{} intVal struct{ val *big.Int } // Int values not representable as an int64 ratVal struct{ val *big.Rat } // Float values representable as a fraction floatVal struct{ val *big.Float } // Float values not representable as a fraction complexVal struct{ re, im Value } ) const prec = 512 func (unknownVal) String() string { return "unknown" } func (x intVal) String() string { return x.val.String() } func (x ratVal) String() string { return rtof(x).String() } func (x floatVal) String() string { f := x.val // Use exact fmt formatting if in float64 range (common case): // proceed if f doesn't underflow to 0 or overflow to inf. if x, _ := f.Float64(); f.Sign() == 0 == (x == 0) && !math.IsInf(x, 0) { return fmt.Sprintf("%.6g", x) } return "OOPS" } func (x complexVal) String() string { return fmt.Sprintf("(%s + %si)", x.re, x.im) } func newFloat() *big.Float { return new(big.Float).SetPrec(prec) } //go:noinline //go:registerparams func itor(x intVal) ratVal { return ratVal{nil} } //go:noinline //go:registerparams func itof(x intVal) floatVal { return floatVal{nil} } func rtof(x ratVal) floatVal { return floatVal{newFloat().SetRat(x.val)} } type Value interface { String() string } //go:noinline //go:registerparams func ToFloat(x Value) Value { switch x := x.(type) { case intVal: if smallInt(x.val) { return itor(x) } return itof(x) case ratVal, floatVal: return x case complexVal: if Sign(x.im) == 0 { return ToFloat(x.re) } } return unknownVal{} } //go:noinline //go:registerparams func smallInt(x *big.Int) bool { return false } //go:noinline //go:registerparams func Sign(x Value) int { return 0 } func main() { v := ratVal{big.NewRat(22,7)} s := ToFloat(v).String() fmt.Printf("s=%s\n", s) }