Skip to content

Commit

Permalink
Merge pull request #754 from gopcua/fs/use-maps-slices
Browse files Browse the repository at this point in the history
use maps and slices from the stdlib
  • Loading branch information
magiconair authored Dec 5, 2024
2 parents 7c3c4fb + a1ed317 commit 476afe8
Show file tree
Hide file tree
Showing 8 changed files with 7 additions and 14 deletions.
2 changes: 1 addition & 1 deletion client_sub.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@ import (
"context"
"io"
"log"
"slices"
"time"

"github.com/gopcua/opcua/debug"
"github.com/gopcua/opcua/errors"
"github.com/gopcua/opcua/stats"
"github.com/gopcua/opcua/ua"
"github.com/gopcua/opcua/uasc"
"golang.org/x/exp/slices"
)

// Subscribe creates a Subscription with given parameters.
Expand Down
3 changes: 1 addition & 2 deletions debug/debug.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,8 @@ import (
"log"
"os"
"runtime"
"slices"
"strings"

"golang.org/x/exp/slices"
)

// Flags contains the debug flags set by OPC_DEBUG.
Expand Down
1 change: 0 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ go 1.22.0
require (
github.com/google/uuid v1.3.0
github.com/pascaldekloe/goe v0.1.1
golang.org/x/exp v0.0.0-20241204233417-43b7b7cde48d
golang.org/x/term v0.8.0
)

Expand Down
2 changes: 0 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I=
github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
github.com/pascaldekloe/goe v0.1.1 h1:Ah6WQ56rZONR3RW3qWa2NCZ6JAVvSpUcoLBaOmYFt9Q=
github.com/pascaldekloe/goe v0.1.1/go.mod h1:KSyfaxQOh0HZPjDP1FL/kFtbqYqrALJTaMafFUIccqU=
golang.org/x/exp v0.0.0-20241204233417-43b7b7cde48d h1:0olWaB5pg3+oychR51GUVCEsGkeCU/2JxjBgIo4f3M0=
golang.org/x/exp v0.0.0-20241204233417-43b7b7cde48d/go.mod h1:qj5a5QZpwLU2NLQudwIN5koi3beDhSAlJwa67PuM98c=
golang.org/x/sys v0.8.0 h1:EBmGv8NaZBZTWvrbjNoL6HVt+IVy3QDQpJs7VRIw3tU=
golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.8.0 h1:n5xxQn2i3PC0yLAbjTpNT85q/Kgzcr2gIoX9OrJUols=
Expand Down
2 changes: 1 addition & 1 deletion server/monitored_item_service.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@ package server

import (
"errors"
"slices"
"sync"
"sync/atomic"
"time"

"github.com/gopcua/opcua/ua"
"github.com/gopcua/opcua/uasc"
"golang.org/x/exp/slices"
)

// MonitoredItemService implements the MonitoredItem Service Set.
Expand Down
5 changes: 2 additions & 3 deletions server/node.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,10 @@ package server

import (
"log"
"maps"
"slices"
"time"

"golang.org/x/exp/maps"
"golang.org/x/exp/slices"

"github.com/gopcua/opcua/id"
"github.com/gopcua/opcua/server/attrs"
"github.com/gopcua/opcua/server/refs"
Expand Down
3 changes: 1 addition & 2 deletions server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,11 @@ import (
"fmt"
"log"
"net"
"slices"
"strings"
"sync"
"time"

"golang.org/x/exp/slices"

"github.com/gopcua/opcua/id"
"github.com/gopcua/opcua/schema"
"github.com/gopcua/opcua/ua"
Expand Down
3 changes: 1 addition & 2 deletions server/view_service.go
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
package server

import (
"slices"
"time"

"golang.org/x/exp/slices"

"github.com/gopcua/opcua/id"
"github.com/gopcua/opcua/ua"
"github.com/gopcua/opcua/uasc"
Expand Down

0 comments on commit 476afe8

Please sign in to comment.