[BART] torch 1.0 compatibility
This PR contains two minor fixes and one piece of cleanup for the BartModel.

**1.** Previously, Bart's encoder padding mask used -10000. to represent tokens that should be ignored, then called `masked_fill(mask.to(torch.bool), -inf)` to use the mask.

There are two problems with this:
- it's confusing to set a value to a large negative and then call `bool`. Why not just invert the mask and call `bool` immediately.
- `torch.bool` is released in pytorch 1.2, so this code breaks on earlier versions.
- Fix: let `torch.eq` make the mask the correct dtype at the beginning.


**2.** explicit use of `F.gelu` is not allowed/or broken in earlier torch versions. Let `ACT2FN` handle this logic. 

**3.** An unreachable code branch is deleted.


Supplementary Material: torch v 1.2.0 [release notes](https://github.com/pytorch/pytorch/releases/tag/v1.2.0)


# [Codecov](https://codecov.io/gh/huggingface/transformers/pull/3322?src=pr&el=h1) Report
> Merging [#3322](https://codecov.io/gh/huggingface/transformers/pull/3322?src=pr&el=desc) into [master](https://codecov.io/gh/huggingface/transformers/commit/38a555a83c8aceae77895d325174af5bd576cec7&el=desc) will **decrease** coverage by `0.93%`.
> The diff coverage is `70.00%`.

[![Impacted file tree graph](https://codecov.io/gh/huggingface/transformers/pull/3322/graphs/tree.svg?width=650&height=150&src=pr&token=9qOlN6Hb1c)](https://codecov.io/gh/huggingface/transformers/pull/3322?src=pr&el=tree)

```diff
@@            Coverage Diff             @@
##           master    #3322      +/-   ##
==========================================
- Coverage   77.14%   76.20%   -0.94%     
==========================================
  Files         100      100              
  Lines       16972    16964       -8     
==========================================
- Hits        13093    12928     -165     
- Misses       3879     4036     +157     
```


| [Impacted Files](https://codecov.io/gh/huggingface/transformers/pull/3322?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [src/transformers/modeling\_bart.py](https://codecov.io/gh/huggingface/transformers/pull/3322/diff?src=pr&el=tree#diff-c3JjL3RyYW5zZm9ybWVycy9tb2RlbGluZ19iYXJ0LnB5) | `97.04% <70.00%> (+0.78%)` | :arrow_up: |
| [src/transformers/modeling\_tf\_pytorch\_utils.py](https://codecov.io/gh/huggingface/transformers/pull/3322/diff?src=pr&el=tree#diff-c3JjL3RyYW5zZm9ybWVycy9tb2RlbGluZ190Zl9weXRvcmNoX3V0aWxzLnB5) | `8.72% <0.00%> (-81.21%)` | :arrow_down: |
| [src/transformers/modeling\_roberta.py](https://codecov.io/gh/huggingface/transformers/pull/3322/diff?src=pr&el=tree#diff-c3JjL3RyYW5zZm9ybWVycy9tb2RlbGluZ19yb2JlcnRhLnB5) | `85.71% <0.00%> (-10.00%)` | :arrow_down: |
| [src/transformers/modeling\_xlnet.py](https://codecov.io/gh/huggingface/transformers/pull/3322/diff?src=pr&el=tree#diff-c3JjL3RyYW5zZm9ybWVycy9tb2RlbGluZ194bG5ldC5weQ==) | `73.48% <0.00%> (-2.30%)` | :arrow_down: |
| [src/transformers/modeling\_ctrl.py](https://codecov.io/gh/huggingface/transformers/pull/3322/diff?src=pr&el=tree#diff-c3JjL3RyYW5zZm9ybWVycy9tb2RlbGluZ19jdHJsLnB5) | `96.00% <0.00%> (-2.23%)` | :arrow_down: |
| [src/transformers/modeling\_openai.py](https://codecov.io/gh/huggingface/transformers/pull/3322/diff?src=pr&el=tree#diff-c3JjL3RyYW5zZm9ybWVycy9tb2RlbGluZ19vcGVuYWkucHk=) | `80.20% <0.00%> (-1.35%)` | :arrow_down: |
| [src/transformers/modeling\_tf\_utils.py](https://codecov.io/gh/huggingface/transformers/pull/3322/diff?src=pr&el=tree#diff-c3JjL3RyYW5zZm9ybWVycy9tb2RlbGluZ190Zl91dGlscy5weQ==) | `88.19% <0.00%> (+0.71%)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/huggingface/transformers/pull/3322?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/huggingface/transformers/pull/3322?src=pr&el=footer). Last update [38a555a...d67639d](https://codecov.io/gh/huggingface/transformers/pull/3322?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
<|||||>One note: you can add an `activation_function` attribute in `BartConfig` defaulting to "gelu" to be used when calling the `ACT2FN`. This lets people switch to "gelu_new" if they want a different trade-off accuracy versus speed/memory.