Where is the code making OP_RETURN a standard transaction type?
This is the PR that made OP_RETURN outputs standard:


  https://github.com/bitcoin/bitcoin/pull/2738


The commit:


  https://github.com/jgarzik/bitcoin/commit/a79342479f577013f2fd2573fb32585d6f4981b3


The current code:


  https://github.com/bitcoin/bitcoin/blob/v0.11.0/src/script/standard.cpp#L56-L58


    if (GetBoolArg("-datacarrier", true))
        mTemplates.insert(make_pair(TX_NULL_DATA, CScript() &lt;&lt; OP_RETURN &lt;&lt; OP_SMALLDATA));
    mTemplates.insert(make_pair(TX_NULL_DATA, CScript() &lt;&lt; OP_RETURN));