Keno / Keno/DeprecationBotTest

Incorrect bot action in Keno/DeprecationBotTest

Open
#10 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Julia
Stars
1
Forks
1
PR merge metrics
No merged PRs in 30d

Description

@Keno has indicated an incorrect bot action on the Keno/DeprecationBotTest repository.
The relevant snippets are shown below:

```diff
@@ -1,28 +1,24 @@
module DeprecationBotTest

-function foobar{T}(x, y::T)
+function foobar(x, y::T) where T
println(x, y)
end

if !(isdefined(Core, :String) && isdefined(Core, :AbstractString))
- function jlconvert(T::Union{Type{Compat.ASCIIString},Type{Compat.UTF8String}}, ::JldFile, ptr::Ptr)
+ function jlconvert(T::Union{Type{String},Type{String}}, ::JldFile, ptr::Ptr)
strptr = unsafe_load(convert(Ptr{Ptr{UInt8}}, ptr))
n = Int(ccall(:strlen, Csize_t, (Ptr{UInt8},), strptr))
T(unsafe_wrap(Array, strptr, n, true))
end
end

-if VERSION >= v"0.1.0"
- _foo(x) = foo(x)
-else
- _foo(x) = foo(x)
-end
+_foo(x) = foo(x)
```
```diff
@@ -1,28 +1,24 @@
module DeprecationBotTest

-function foobar{T}(x, y::T)
+function foobar(x, y::T) where T
println(x, y)
end

if !(isdefined(Core, :String) && isdefined(Core, :AbstractString))
- function jlconvert(T::Union{Type{Compat.ASCIIString},Type{Compat.UTF8String}}, ::JldFile, ptr::Ptr)
+ function jlconvert(T::Union{Type{String},Type{String}}, ::JldFile, ptr::Ptr)
strptr = unsafe_load(convert(Ptr{Ptr{UInt8}}, ptr))
n = Int(ccall(:strlen, Csize_t, (Ptr{UInt8},), strptr))
T(unsafe_wrap(Array, strptr, n, true))
end
end

-if VERSION >= v"0.1.0"
- _foo(x) = foo(x)
-else
- _foo(x) = foo(x)
-end
+_foo(x) = foo(x)

bar(x) = _foo(x)

-function foobar{T}(a,
- b::T,
- c::T)
+function foobar(a,
```

Contributor guide

No contributing guide indexed for this repository

Research direction

The issue provides generated diffs from Keno/DeprecationBotTest but names no source file or test entry point. Start by locating the bot action that produced these snippets and compare its handling of the shown Julia syntax; done means the repository records the correct action for this case.

Written by the indexing model from the issue text.

Assessment

Tech stack
github, julia
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.