Skip to content

Commit

Permalink
Merge pull request DefinitelyTyped#2548 from Bartvds/def/node
Browse files Browse the repository at this point in the history
node.d.ts : pass Uint8Array to Buffer constructor
  • Loading branch information
Bartvds committed Jul 29, 2014
2 parents 5a615a2 + 1d60391 commit b1b3718
Showing 1 changed file with 14 additions and 12 deletions.
26 changes: 14 additions & 12 deletions node/node.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ declare var exports: any;
declare var SlowBuffer: {
new (str: string, encoding?: string): Buffer;
new (size: number): Buffer;
new (size: Uint8Array): Buffer;
new (array: any[]): Buffer;
prototype: Buffer;
isBuffer(obj: any): boolean;
Expand All @@ -63,6 +64,7 @@ interface Buffer extends NodeBuffer {}
declare var Buffer: {
new (str: string, encoding?: string): Buffer;
new (size: number): Buffer;
new (size: Uint8Array): Buffer;
new (array: any[]): Buffer;
prototype: Buffer;
isBuffer(obj: any): boolean;
Expand Down Expand Up @@ -760,18 +762,18 @@ declare module "net" {
declare module "dgram" {
import events = require("events");

interface RemoteInfo {
address: string;
port: number;
size: number;
}
interface AddressInfo {
address: string;
family: string;
port: number;
}
interface RemoteInfo {
address: string;
port: number;
size: number;
}
interface AddressInfo {
address: string;
family: string;
port: number;
}
export function createSocket(type: string, callback?: (msg: Buffer, rinfo: RemoteInfo) => void): Socket;

interface Socket extends events.EventEmitter {
Expand Down

0 comments on commit b1b3718

Please sign in to comment.