removed deprecated message in FieldType
merged branch fabpot/deprecated-calls (PR #6868)

This PR was merged into the master branch.

Commits
-------

ed64413 removed deprecated message in FieldType

Discussion
----------

removed deprecated messages coming for internal calls

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #6407
| License       | MIT
| Doc PR        | n/a

It's probably not the cleanest code possible, but I don't see any other way to keep the type for BC and avoid the deprecated message when called internally.

That should fix the deprecated messages thrown by the Form and Validator components.

---------------------------------------------------------------------------

by stof at 2013-01-24T15:41:26Z

The cases where you should actually be warned about the deprecation of FieldType is when using ``field`` to create a field with the factory (which would not trigger the constructor)

---------------------------------------------------------------------------

by fabpot at 2013-01-24T15:46:23Z

@stof: what do you mean? That we can remove the `trigger_error()` call altogether?

---------------------------------------------------------------------------

by stof at 2013-01-24T15:49:31Z

Nobody will ever instantiate the FieldType directly as the framework is registering it (btw, you are missing the FrameworkBundle lazy registration here).
The constructor of a form type is not the right place to deprecate it as registering it does not mean it will be used in the app.

---------------------------------------------------------------------------

by fabpot at 2013-01-24T15:51:26Z

@stof: I've updated the PR to remove the `trigger_error` call.