[Tex/LaTex] Using usepackage twice with the same package name

packages

I've seen duplicated package inclusion multiple times in questions. I've looming memories of comments like "it's a really bad thing to do" (which I couldn't find).

I was wondering what are the drawbacks of doing something like this. Other than realisation like "I've deleted the \usepackage but my code still uses the package".

Example:

\usepackage{floatrow}
...
\usepackage{tikz,floatrow,hyperref}

What troubles can be caused that way other than "bad sourcecode"?

Best Answer

LaTeX detects this and skips the second without loading it. Unless you have incompatible options, in which case you get an error. so it's not bad, it was designed that way as a feature, so you could have two packages each loading (say) color, and color only getting loaded once.

Related Question