Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(77)

Delta Between Two Patch Sets: windows/syscall_windows_test.go

Issue 126960043: code review 126960043: go.sys: copy files from syscall package to go.sys/{plan... (Closed)
Left Patch Set: Created 10 years, 7 months ago
Right Patch Set: diff -r 89b705e036f489a14b4d11c6e025ea61a53bb735 https://code.google.com/p/go.sys Created 10 years, 7 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
« no previous file with change/comment | « windows/syscall_windows_amd64.go ('k') | windows/zerrors_windows.go » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
(Both sides are equal)
1 // Copyright 2012 The Go Authors. All rights reserved. 1 // Copyright 2012 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style 2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file. 3 // license that can be found in the LICENSE file.
4 4
5 package syscall_test 5 package syscall_test
6 6
7 import ( 7 import (
8 "io/ioutil" 8 "io/ioutil"
9 "os" 9 "os"
10 "path/filepath" 10 "path/filepath"
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 proc, err := syscall.GetProcAddress(h, "GetVersion") 63 proc, err := syscall.GetProcAddress(h, "GetVersion")
64 if err != nil { 64 if err != nil {
65 abort("GetProcAddress", err) 65 abort("GetProcAddress", err)
66 } 66 }
67 r, _, _ := syscall.Syscall(uintptr(proc), 0, 0, 0, 0) 67 r, _, _ := syscall.Syscall(uintptr(proc), 0, 0, 0, 0)
68 major := byte(r) 68 major := byte(r)
69 minor := uint8(r >> 8) 69 minor := uint8(r >> 8)
70 build := uint16(r >> 16) 70 build := uint16(r >> 16)
71 print("windows version ", major, ".", minor, " (Build ", build, ")\n") 71 print("windows version ", major, ".", minor, " (Build ", build, ")\n")
72 } 72 }
LEFTRIGHT

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b