Mohamed Hegazy

Results 54 comments of Mohamed Hegazy

We need new overloads to freeze,: ```ts freeze(a: Map): ReadonlyMap; ``` and set as well since we are at it: ```ts freeze(a: Set): ReadonlySet; ```

duplicate of #3136?

We should specify the `this` in the `set` and `get` of property descriptors.

we need to change the defineProperty declaration in the library to be ```ts defineProperty(o: any, propertyKey: PropertyKey, attributes: PropertyDescriptor & ThisType): any; ```

`T` is not sufficient, since you are adding a new property `p` in this call. so ideally it should be something like `T & {[ P in K] : V}`...

>>we need to change the defineProperty declaration in the library to be > In what library? just in lib.d.ts? there are two sources for this declaration, one of them is...

We should put any additional information for this in the handbook module page: https://github.com/Microsoft/TypeScript-Handbook/blob/master/pages/Modules.md we can also add a link to that page in the FAQ page.

There are a few complications for the proposal in the OP, first as you noted the compiler does not know that `array.psuh` is a mutating function and should not be...

We need a proposal for this feature. Pre-processor directives (i.e.`#ifdef`s) are not desirable. But something along the lines of [Conditional in C#](https://msdn.microsoft.com/en-us/library/4xssyw96%28v=vs.90%29.aspx) would be more like it. Either ways we...